<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="UTF-8">
        <title>Title</title>
        <style>

            .animation{
                width: 100px;
                height: 100px;
                background-color: red;
                animation: myfirst 5s;
                -webkit-animation:myfirst 5s;
            }

            @keyframes myfirst {
                from{background: red;}
                to{background: yellow;}
            }

            @-webkit-keyframes myfirst{
                from{background: red;}
                to{background: yellow;}
            }

        </style>
    </head>
    <body>

        <div class="animation"></div>

    </body>
</html>